<div id="bluecoat-list">
  <h1>Users</h1>

  <table cellpadding="5" cellspacing="0">
    <% for user in @active_users %>
      <tr class="<%= cycle('list-line-odd', 'list-line-even') %>">
        <td class="list-title">
          <%= link_to "X", { :action => :destroy, :id => user },
                             :method => :post %>
        </td>
        <td class="list-title">
          <%= link_to h(user.name), :action => :edit, :id => user %>
        </td>
        <% if user.admin? %>
          <td>admin user</td>
        <% end %>
        <% if user.can_deploy? %>
          <td>can deploy to firewalls</td>
        <% end %>
      </tr>
    <% end %>
  </table>

  <% unless @inactive_users.empty? %>
    <h1>Deleted Users</h1>
    <table cellpadding="5" cellspacing="0">
      <% for user in @inactive_users %>
        <tr class="<%= cycle('list-line-odd', 'list-line-even') %>">
          <td class="list-title">
            <%= h(user.name) %>
          </td>
          <td class="list-actions">
            <%= link_to "Activate", { :action => :activate, :id => user },
                                    :method => :post %>
          </td>
          <% if user.admin? %>
            <td>admin user</td>
          <% end %>
          <% if user.can_deploy? %>
            <td>can deploy to firewalls</td>
          <% end %>
        </tr>
      <% end %>
    </table>
  <% end %>
</div>
